<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>layui</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="../../js/css/layui.css">
    <!-- 注意：如果你直接复制所有代码到本地，上述css路径需要改成你本地的 -->
</head>
<body>
<style>
    .serach_input{ width: 180px; margin-right: 5px;}
    .padding_top{ margin-top: 0px;}
</style>
<table class="layui-hide" id="test" lay-filter="test"></table>

<script type="text/html" id="barDemo">
    <a class="layui-btn layui-btn-xs" lay-event="edit">打包下载</a>
    <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="del">删除目录</a>
</script>
<script type="text/html" id="barDemo1">
    <a class="layui-btn layui-btn-xs" lay-event="edit">查看备份说明</a>
</script>
<script src="../layui.all.js"></script>
<!-- 注意：如果你直接复制所有代码到本地，上述js路径需要改成你本地的 -->
<script>
    layui.use('table', function(){
        var table = layui.table;
        var laydate = layui.laydate;
        laydate.render({
            elem: "#date"
            ,type: 'datetime'
        });
        laydate.render({
            elem: "#date1"
            ,type: 'datetime'
        });
        table.render({
            elem: '#test'
            ,data:[
                {
                    "id":1,
                    'title':"新闻系统表（phone_cms_new）",
                    "publish":"admin",
                },
                {
                    "id":1,
                    'title':"新闻系统表（phone_cms_new）",
                },
                {
                    "id":1,
                    'title':"新闻系统表（phone_cms_new）",
                },
                {
                    "id":1,
                    'title':"新闻系统表（phone_cms_new）",
                },
            ]
            // ,url:'/test/table/demo1.json'
            ,title: '管理备份目录'
            ,cols: [[
                {field:'id', title:'ID', width:80, fixed: 'left', unresize: true, sort: true}
                ,{field:'title', title:'备份目录名',width:350}
                ,{field:'publish', title:'查看说明文件',toolbar: '#barDemo1'}
                ,{fixed: 'right', title:'操作', toolbar: '#barDemo'}
            ]]
            ,page: true
            ,count:20
            ,limit:12
            ,loading:true
            ,size:'lg'
        });
    });
</script>

</body>
</html>